﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace System
{
    public static class LabelExtension
    {
        public static void SuccessMessage(this System.Web.UI.WebControls.Label label, string message)
        {
            label.Text = "<p>" + message + "</p>";
            label.CssClass = "msg msg-ok";
        }

        public static void ErrorMessage(this System.Web.UI.WebControls.Label label, string message)
        {
            label.Text = "<p>" + message + "</p>";
            label.CssClass = "msg msg-error";
        }

        public static void WarningMessage(this System.Web.UI.WebControls.Label label, string message)
        {
            label.Text = "<p>" + message + "</p>";
            label.CssClass = "msg msg-warn";
        }

        public static void InfoMessage(this System.Web.UI.WebControls.Label label, string message)
        {
            label.Text = "<p>" + message + "</p>";
            label.CssClass = "msg msg-info";
        }
    }
}